import { createRouter, createWebHistory, RouteRecordRaw } from 'vue-router'
const routes: Array<RouteRecordRaw> = [
  { path: '/', name: "IndexItem", meta: { title: '首页' }, component: () => import('@/views/IndexItem.vue') }, // 首页
  { path: '/chat', name: "Chat", meta: { title: 'AI客服' }, component: () => import('@/views/chat.vue') },
  // { path: '/voice', name: "Voice", meta: { title: '录音' }, component: () => import('@/views/voice.vue') },
  { path: '/show', name: "Show", meta: { title: '演出' }, component: () => import('@/views/show.vue') },
  // { path: '/toMini', name: "ToMini", meta: { title: '跳转' }, component: () => import('@/views/toMini.vue') },
]
const router = createRouter({
  history: createWebHistory(import.meta.env.VITE_ROUTER_BASE),
  routes
})
router.beforeEach(async (to, from, next) => {
  next()
})
export default router
